﻿@model HotDealD2.Models.ModelView.PromotionView
@{
    Layout = "../Shared/BusinessLayout.cshtml";
}


<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" lang="vn">
<head>
<title>Đơn hàng - HotDeal.vn: Cùng mua chung, mua theo nhóm, mua deal giá rẻ</title>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta http-equiv="Content-Language" content="vn" />
<meta name="description" content="Cùng mua chung theo nhóm, mua các deal sản phẩm và dịch vụ giảm giá, rẻ tới 90%: mua sắm, du lịch, làm đẹp, ăn uống, nhà hàng, thời trang, spa tại HotDeal.vn" />
<meta name="keywords" content="hotdeal, hotdeals, hot deal, mua hàng theo nhóm,mua chung, nhóm mua, cùng mua, deal, deals, giá tốt, giá rẻ, giảm giá, khuyến mại, ưu đãi, Group Buy, daily deals" />
<meta name="SKYPE_TOOLBAR" content="SKYPE_TOOLBAR_PARSER_COMPATIBLE" />
<meta name="robots" content="noindex" />
<link type="text/css" href="../../../../Content/BusinessSite/stylesheets/IndexBusiness.css" rel="stylesheet"/>
</head>
<body class="c-orders m-search cm-orders-search">                                   
    <div class="content_general">
        <h1 class="mainbox-title"><span>Danh sách đơn đặt hàng</span></h1>
        <div class="mainbox-body">
            <div class="section-border search-form" id="ds_1798439440">
                <h2 class="subheader">
                    Thống kê đơn hàng
                </h2>
                
                <div id="s_8929ef313c0fd6e43446cc0aa86b70cd" class="section-body ">	
                    @using (Html.BeginForm("ListOrdered", "Business", FormMethod.Get, new { id = Model.ProStatisticView.IDPromotion.Value}))
                    {
                        <div class="buttons-container" style="text-align:left">
                            <span class="button-submit"><input   type="submit"   value="Cập nhật" /></span>
                        </div>

                        <table border="0" cellpadding="0" cellspacing="0" width="100%" class="table">
                            <tr>
                                <th width="4%"><a class="" href="/quan-ly-don-hang?sort_by=order_id&amp;sort_order=asc" rev="pagination_contents">Mã deal</a></th>
                                <th width="20%">Tên deal</th>
                                <th width="15%"><a class="" href="/quan-ly-don-hang?sort_by=status&amp;sort_order=asc" rev="pagination_contents">Ngày đăng</a></th>
                                <th width="15%"><a class="" href="/quan-ly-don-hang?sort_by=date&amp;sort_order=asc" rev="pagination_contents">Hạn sử dụng</a></th>
                                <th width="15%" class="right"><a class="" href="/quan-ly-don-hang?sort_by=total&amp;sort_order=asc" rev="pagination_contents">Giá tốt</a></th>
                                <th width="15%"><a class="" href="/quan-ly-don-hang?sort_by=date&amp;sort_order=asc" rev="pagination_contents">Số lượng tối đa</a></th>
                                <th width="15%"><a class="" href="/quan-ly-don-hang?sort_by=date&amp;sort_order=asc" rev="pagination_contents">Đơn giá (VNĐ)</a></th>
                                <th width="15%"><a class="" href="/quan-ly-don-hang?sort_by=date&amp;sort_order=asc" rev="pagination_contents">Số lượng</a></th>
                                <th width="15%"><a class="" href="/quan-ly-don-hang?sort_by=date&amp;sort_order=asc" rev="pagination_contents">Thành tiền (VNĐ)</a></th>
                                <th width="15%"><a class="" href="/quan-ly-don-hang?sort_by=date&amp;sort_order=asc" rev="pagination_contents">Tình trạng</a></th>
                            </tr>

                            <tr>
                                <td class="center">
                                    <a href="/chi-tiet-don-hang?order_id=2058950"><strong>@Html.DisplayFor(m => m.ProStatisticView.IDPromotion)</strong></a>
                                </td>
                                <td>
                                    <ul class="no-markers">
                                        <li>@Html.DisplayFor(m => m.ProStatisticView.TenDeal)</li>
                                    </ul>
                                </td>
                                    <td class="center">@Html.DisplayFor(m => m.ProStatisticView.NgayDang)</td>
                                    <td class="center">@Html.DisplayFor(m => m.ProStatisticView.HanSuDung)</td>
                                    <td class="center">@Html.DisplayFor(m => m.ProStatisticView.TinhTrangGiaTot)</td>
                                    <td class="center">@Html.DisplayFor(m => m.ProStatisticView.SoLuongToiDa)</td>
                                    <td class="center">@Html.DisplayFor(m => m.ProStatisticView.GiaTien)</td>
                                    <td class="center">@Html.DisplayFor(m => m.ProStatisticView.TongSoDonHang)</td>
                                    <td class="center">@Html.DisplayFor(m => m.ProStatisticView.ThongKeSoTien)</td>
                                    <td class="center">@Html.DisplayFor(m => m.ProStatisticView.TinhTrang)</td>
                                            
                             </tr>

                            <tr class="table-footer">
                                <td colspan="10">&nbsp;</td>
                            </tr>
                        </table>
                    }
                </div>
            </div>

            <br />
            <div class="pagination-container" id="pagination_contents">
                <h2 class="subheader">
                    Danh sách đơn hàng
                </h2>
                <table border="0" cellpadding="0" cellspacing="0" width="100%" class="table">
                    <tr>
                        <th width="20%"><a class="" href="/quan-ly-don-hang?sort_by=order_id&amp;sort_order=asc" rev="pagination_contents">Đơn hàng</a></th>
                        <th width="20%"><a class="" href="/quan-ly-don-hang?sort_by=order_id&amp;sort_order=asc" rev="pagination_contents">Mã deal</a></th>
                        <th width="20%"><a class="" href="/quan-ly-don-hang?sort_by=date&amp;sort_order=asc" rev="pagination_contents">Ngày đặt</a>&nbsp;&nbsp;&#8595;</th>
                        <th width="20%"><a class="" href="/quan-ly-don-hang?sort_by=order_id&amp;sort_order=asc" rev="pagination_contents">Số lượng</a></th>
                        <th width="20%"><a class="" href="/quan-ly-don-hang?sort_by=status&amp;sort_order=asc" rev="pagination_contents">Trạng thái</a></th>
                        <th width="20%" class="right"><a class="" href="/quan-ly-don-hang?sort_by=total&amp;sort_order=asc" rev="pagination_contents">Thành tiền (VNĐ)</a></th>
                    </tr>
                    
                    @{
                        bool isOdd = true;
                        foreach (var item in Model.OrderView)
                        {
                            if (isOdd)
                            {
                                <tr>
                                    <td class="center">
                                        <a href="/chi-tiet-don-hang?order_id=2058950"><strong>@Html.DisplayFor(m => item.MaDonHang)</strong></a>
                                    </td>
                                    <td>
                                        <ul class="no-markers">
                                            <li>@Html.DisplayFor(m => item.MaDeal)</li>
                                        </ul>
                                    </td>
                                     <td>@Html.DisplayFor(m => item.NgayDat)</td>
                                     <td>@Html.DisplayFor(m => item.SoLuong)</td>
                                     <td>@Html.DisplayFor(m => item.TinhTrang)</td>
                                     <td>@Html.DisplayFor(m => item.TongCong)</td>
                                </tr>
                                isOdd = false;
                            }
                            else
                            { 
                                <tr class="table-row">
                                    <td class="center">
                                        <a href="/chi-tiet-don-hang?order_id=2058950"><strong>@Html.DisplayFor(m => item.MaDonHang)</strong></a>
                                    </td>
                                    <td>
                                        <ul class="no-markers">
                                            <li>@Html.DisplayFor(m => item.MaDeal)</li>
                                       </ul>
                                    </td>
                                    <td>@Html.DisplayFor(m => item.NgayDat)</td>
                                    <td>@Html.DisplayFor(m => item.SoLuong)</td>
                                    <td>@Html.DisplayFor(m => item.TinhTrang)</td>
                                    <td>@Html.DisplayFor(m => item.TongCong)</td>
                                </tr>
                                isOdd = true;
                             }
                        }
                    }
                        <tr class="table-footer">
                            <td colspan="6">&nbsp;</td>
                        </tr>
                </table>
            </div>
        </div>
    </div>  
</body>
</html><!--WSS-->

